1. Field of the Invention
This invention relates to information storage systems, and in particular to a method for the management of storage media defects in disk drives.
2. Description of the Prior Art
Media are commonly used for storage of information in data processing. Examples of such media are magnetic disks and tapes. An increase in the media storage capacity per unit of area tends to increase the occurrence of defects in the media. Defects are flaws in the media that make portions of the media unusable, and are the result of imperfections in the media manufacturing process.
As the storage capability of bulk storage media is increased, it is more difficult to manufacture defect-free storage media devices, and it becomes costly to scrap flawed media. Thus a method is needed to permit the use of storage media having flawed sections.
In U.S. Pat. No. 4,498,146, issued Feb. 5, 1985, Martinez discloses a typical prior art method for avoiding accessing defective locations in storage media. A table of addresses of defective locations is first constructed. When an address is obtained for accessing a location in the storage medium, the contents of the address table are read to determine if access to the media will be impacted by defective locations, and the address is modified to avoid usage of defective locations. The storage location designated by the modified address is then accessed. If none of the defective locations impact the access, the storage location designated by the obtained address is accessed. The above process is carried out during execution of the operation for whose execution the address was obtained. The essence of the prior art therefore is keeping a complete list having a separate entry for each of the defective (i.e., "bad") storage locations on the media of a disk drive.
The address table comprises an ordered list of the addresses of defective locations. The obtained address is a logical address, while the modified address is a physical address. Contents of the table are read to determine the number of defective locations that affect the access, and the logical address is translated into the physical address by using the determined number of defective locations in the translation.
A typical prior art disk drive 10 is shown in FIG. 1. Disk drive 10 includes disks 53 which are the magnetic storage media. A drive motor 51 spins the disks 53 past read and write heads 57 which access selected portions of the disks 53 for data storage and retrieval. Motion of the heads 57 and selection of one or more particular heads are performed by head positioning and selecting circuitry 52, which operates under control of disk microprocessor 12.
As shown in FIG. 1, there are a plurality of disks 53. Each disk 53 has one head 57 associated therewith. The surface of each disk 53 is divided into a plurality of circular concentric tracks 54. In this case, only one surface (i.e., side) of each disk 53 is in use. It is well known to use both surfaces of each disk 53 for recording, by providing a head for each surface. Tracks 54 on all of the disks 53 which lie the same radial distance away from the centers of the disks 53 logically form a cylindrical surface referred to as a cylinder 55. Thus each track 54 of each disk 53 lies in a unique cylinder 55. Each track 54 is furthermore logically subdivided into a plurality of segments or areas, typically referred to as sectors or blocks 56. Disk drive 10 including microprocessor 12 and RAM (Random Access Memory) associated with microprocessor 12 is connected to host computer 15 by means of disk controller 17.
The cylinders 55, tracks 54, and sectors 56 are used to define graduations in the size of storage locations of the disk drive 10. Hence, addressing within the disk drive 10 is accomplished by specifying a head 57, to select one of the disks 53, a cylinder 55, to select a particular track 54 on each disk 53, and a sector 56 to select a data block.
Prior to providing the disk drive 10 to the user, the manufacturer of the disk drive 10 tests it for defects. The manufacturer's specifications for the particular disk drive type include the maximum number of defects that the disk drive 10 is allowed to have. If the specified maximum number of defects is not exceeded, the disk drive 10 is considered to be usable. The manufacturer supplies with the disk drive 10 information about the disk drive 10 which includes the sites of the defects in the disk drive 10. The manufacturer typically stores this information in a defect table (further described below) which is located on a particular reserved track 54 (see FIG. 1) of one of the disks 53.
Each sector 56 includes conventionally a header area (not shown) at the beginning of the sector 56. The header area includes a place for the sector address. As part of the formatting of the disk drive 10 (either at the factory or by the user), a sector address is written in each sector header area. Bad (i.e., flawed) sectors are typically identified and the defect list is constructed accordingly by specialized testing equipment by the disk drive manufacturer. Some disk drive interface standards (such as SCSI) also include means to detect and list defective sectors when the disk drive is in operation by the user.
FIG. 2A shows a typical track "n" with physical sector numbers (i.e., physical addresses) N, N+1, N+2, . . . N+7; physical sector number N corresponds to logical block number (i.e., logical address) N*. Physical sector number N+1 is a bad sector, and so does not correspond to any logical block number. Physical sector number N+2 corresponds to logical block number N*+1, etc, and physical sector number N+4 is also a bad sector and so does not correspond to any logical block number.
The above description applies to various kinds of storage devices including magnetic recording disk drives (both floppy and hard disk drives) and optical recording disk drives.
Thus in the prior art, a disk drive uses manufacturer-provided information about the location of defects to construct a sequentially ordered defects list of addresses of defective storage locations in the disk drive, and the list is stored in a table on the disk media.
FIG. 2B shows in schematic form such a prior art disk drive sector having the above described defect management scheme. The disk surfaces are labelled as surface 0, surface 1, . . . surface 5. In this example, each surface has 822 physical sectors, numbered consecutively on surface 0 through surface 5. As shown, in this prior art defect management scheme, a bad sector (labeled "BAD") on surface 2 is effectively "replaced" by a good sector selected from one of the good "SPARE SECTORS" on surface 5 by using the replacement list of bad sectors and substitute spare sectors. Thus the good spare sector on surface 5 is assigned the logical block number (i.e., logical block address) that would have been assigned to the bad sector on surface 2 if the bad sector had not been defective.
A prior art defects list corresponding to the structure of FIG. 2B is shown in FIG. 2C. The first column is the logical block address (LBA) number; the cylinder number, head number, and sector number of the bad sector that would have had that LBA number if the sector had not been defective are the next three columns. Then the last three columns show the cylinder number, head number, and sector number of the spare sector assigned to replace the bad sector.
Also known in the art is the "sector slipping" technique for provision of spare sectors. In this case, instead of using spare sectors provided on a separate disk surface, the bad sector is skipped over and the logical block address that would have been associated with the bad sector had it been good is "slipped" to the next good sector on the same track. This method is used in conjunction with a defects list similar to that shown in FIG. 2C.
Such prior art methods have the disadvantage that if a particular disk drive has a significant number of defects, the defects list is very lengthy. This slows down operation of the disk drive whenever the defects list is accessed due to the need to go through the entire list. In addition, in many disk drive controllers (such as the well known SCSI "Small Computer System Interface" controllers) the controller actually keeps track of a logical address of storage locations, rather than a physical address. In this case, the use of a lengthy defects list slows down the calculation of the physical addresses from the logical addresses, since the defects list must be referred to whenever a physical address is calculated.